package com.icloud.common.database.enums;

import lombok.Getter;

@Getter
public enum ArticleForbiddenDownEnum {
    TRUE("TRUE"),
    FALSE("FALSE");

    private final String code;

    ArticleForbiddenDownEnum(String code){
        this.code = code;
    }

    public static ArticleForbiddenDownEnum byCode(String code) {
        for (ArticleForbiddenDownEnum e: ArticleForbiddenDownEnum.values()) {
            if (e.code.equalsIgnoreCase(code)) {
                return e;
            }
        }
        return null;
    }
}
